package com.hw.one.transpot.constant;

import com.hw.one.collect.config.ConditionConfig;

/**
 * @Class TransportDataConstant
 * @Author guoshenzhen
 * @Date 2018/4/3  18:51
 */
public class TransportDataConstant {
    public static final String APPID;
    public static final String APPKEY;

    public static final String IP;
    public static final int PORT;

    static {

        String appId = ConditionConfig.get("appId", ConditionConfig.collectCommon);
        APPID = null == appId ?  "appId" : appId;
        String appKey = ConditionConfig.get("appKey", ConditionConfig.collectCommon);
        APPKEY = null == appKey ? "appKey" : appKey;

        String transferDataIP = ConditionConfig.get("transferDataIP", ConditionConfig.collectCommon);
        IP = null == transferDataIP ? "127.0.0.1" : transferDataIP;
        String transferDataPort = ConditionConfig.get("transferDataPort", ConditionConfig.collectCommon);
        PORT = null == transferDataPort ? 0 : Integer.parseInt(transferDataPort);
    }


}
